<html>
<head>
    <meta charset="UTF-8">
    <title>岗位管理列表</title>
    <link id="easyuiTheme" href="../../static/easyui/themes/bootstrap/easyui.css" rel="stylesheet" type="text/css"/>
    <link href="../../static/easyui/themes/icon.css" rel="stylesheet" type="text/css"/>
    <script src="../../static/easyui/jquery.min.js" type="text/javascript"></script>
    <script src="../../static/easyui/jquery.cookie.js" type="text/javascript"></script>
    <script src="../../static/easyui/ui-theme.js" type="text/javascript"></script>
    <script src="../../static/easyui/jquery.easyui.min.js" type="text/javascript" charset="utf-8"></script>
    <script src="../../static/easyui/locale/easyui-lang-zh_CN.js" type="text/javascript"></script>
    <script src="../../static/plugin/assets/jslib.util.js" type="text/javascript"></script>
    <script src="../../static/plugin/assets/jslib.jquery.ajax.js" type="text/javascript"></script>
    <script src="../../static/plugin/assets/jslib.easyui.util.js" type="text/javascript"></script>
    <script src="../../ffres/dict/all.js" type="text/javascript"></script>
    <a href="" target="_blank" id="commonLink" name="commonLink"></a>
</head>
<body class="easyui-layout">
<div data-options="region:'north'"  style="height: 74px;">
    <div data-options="region:'north',title:''" style="height: 40px;">
        <div class="esaas-info-title2" style="background-color: #205081;" >
            <div style="padding: 2px;"></div>
            &nbsp;&nbsp;选择岗位
            <a class="easyui-menubutton" style="position:absolute;right: 5px;top: 1px;width:22px;height: 22px;background-image: url('../../static/easyui/themes/icons/cancel6.png')"
               onclick="closeForm()"
            >
            </a>
        </div>
        <form id="searchForm">
            <table>
                <tr>
                    <td class="searchTd">&nbsp;岗位代码：</td>
                    <td><input name="dutyCode" id="duty_code"/></td>
                    <td class="searchTd">&nbsp;岗位名称：</td>
                    <td><input name="dutyName" id="duty_name"/></td>
                    <td class="searchTd">&nbsp;状态：</td>
                    <td><input name="dutyName" id="status"/></td>
                    <td><a class="easyui-linkbutton" href="javascript:void(0);" onclick="JLEUtil.queryForm('searchForm','dg','../../api/s/dutys');">查找</a></td>
                    <td><a class="easyui-linkbutton" href="javascript:void(0);" onclick="JLEUtil.clearForm('searchForm');">清空</a></td>
                </tr>
            </table>
        </form>
    </div>
</div>
<div data-options="region:'center',split:false">
    <table id="dg" class="easyui-datagrid" title="" style="width:100%;height:100%"
           data-options="singleSelect:true,collapsible:true,url:'../../api/s/dutys',method:'post'"
           toolbar="#tb"
           title="Load Data"
           rownumbers="true" pagination="true" pageSize="20">
        <thead>
        <tr>
            <th data-options="field:'dutyCode',resizable:true" >岗位代码</th>
            <th data-options="field:'dutyName',resizable:true">岗位名称</th>
            <th data-options="field:'legalOrgCode',resizable:true">机构法人代码</th>
            <th data-options="field:'orderId',resizable:true">排序字段</th>
            <th data-options="field:'dutyType',resizable:true">类型</th>
            <th data-options="field:'memo',resizable:true">备注</th>
            <th data-options="field:'orgId',resizable:true">组织号</th>
            <th data-options="field:'dutyLevel',resizable:true">岗位层级</th>
            <th data-options="field:'dutyParentCode',resizable:true">上级岗位号</th>
            <th data-options="field:'createTime',resizable:true">创建日期</th>
            <th data-options="field:'createUser',resizable:true">创建人</th>
            <th data-options="field:'lastUpdateUser',resizable:true">最后修改人</th>
            <th data-options="field:'lastUpdateTime',resizable:true">最后修改日期</th>
            <th data-options="field:'status',resizable:true">状态</th>
            <th data-options="field:'createOrgCode',resizable:true">创建人所属机构</th>
            <th data-options="field:'orgCode',resizable:true">机构代码</th>
            <!--<th data-options="field:'orderno',resizable:true" >排序字段</th>-->

            <!--<th data-options="field:'memo',resizable:true" >备注</th>-->
            <!--<th data-options="field:'orgid',resizable:true" >机构号</th>-->
        </tr>
        </thead>
    </table>
</div>
<div data-options="region:'south',split:false" style="height: 105px">
    <div style="text-align: center; padding: 30px 0px 30px;height: 40px;">
        <a href="javascript:void(0)" class="easyui-linkbutton"
           onclick="selectReturn()">&nbsp;选择返回&nbsp;</a>
        <a href="javascript:void(0)" class="easyui-linkbutton"
           onclick="closeForm()">&nbsp;关&nbsp;闭&nbsp;</a>
    </div>
</div>

<script type="text/javascript">
		function onDblClickRow(index,row) {
		    window.parent.onChooseSDutyName(row);
		    window.parent.JLEUtil.closewin();
		}
		
		function selectReturn() {
		    var row = $('#dg').datagrid('getSelected');
		    if (row) {
		        onDblClickRow(-1, row);
		    } else {
		        $.messager.alert('提示', '请选择一条记录！', 'info');
		    }
		}
		
		function closeForm() {
		    window.parent.JLEUtil.closewin();
		}
		
		function reloadList(){
		    $('#dg').datagrid('reload');
		    JLEUtil.closewin();
		};

</script>
</body>
</html>
